package acm.浙江24赛;

import java.util.Scanner;

public class 寻找leetcode {
    static final char[] target = "leetcode".toCharArray();
    static char[] origin;

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        origin = sc.nextLine().toCharArray();
        int[] res = new int[origin.length];
        res[0]=find(0)+1;
        for (int i = 1; i < origin.length; i++) {
            if (i <= pre) {  //上一个符合要求的l位置
                res[i]=res[i-1];
            } else {
                res[i] = find(i) + 1;
            }
            if (res[i] == 0) {
                break;
            }
        }
        StringBuilder builder = new StringBuilder();
        for (int i : res) {
            builder.append(i).append(" ");
        }
        builder.deleteCharAt(builder.length() - 1);
        System.out.println(builder);
    }
    static int pre=-1;

    public static int find(int i) {
        int r = i;
        for (int j = 0; j < target.length; j++) {
            while (r < origin.length && origin[r] != target[j]) {
                r++;
            }
            if (j==0){
                pre=r;
            }
        }
        return r < origin.length ? r : -1;
    }
}
